<ul class="level1">
  {foreach $list as $k=>$v}
  <li {if $category_id == $v.id || $v.id == $article_info.category_id || $v.id == $category_top_info.id}class="curr"{/if}>
    <a {if $article_info.category_id}class="js_sltCategory"{/if} href='{AnUrl("article?category_id={$v.id}")}'><em></em>{$v.title}</a>
    {if $category_top_info.id}
    {widget model="article" func="get_list" file="article_title_list.html" category_id=$v.id}
    {/if}
  </li>
  {/foreach}
</ul>
{if $category_top_info.id}
  <div style="border-top:1px solid #222;margin-top:10px;"></div>
  {widget model="article" func="get_list" file="article_title_list.html" category_id=$category_top_info.id}
{/if}
{if $article_info.category_id}
<script>
$(function(){
  $('.js_sltCategory').click(function(e){
    e.preventDefault();
    $(this).parent().siblings().removeClass('curr');
    $(this).parent().addClass('curr');
  });
});
</script>
{/if}